package homework;

import java.util.Scanner;

/**
 * @classname:demo11
 * @description:
 * @author: Mr.Z
 * @date: 2020/12/8 17:38
 * @version: 0.1
 * @since:1.8
 */
public class demo11 {
    public static void main(String[] args) {
        Scanner input = new Scanner(System.in);
        System.out.println("请输入几个文件名字");
        String str = input.next();
        String[] split = str.split(",");
        for (int i = 0; i < split.length; i++) {
            if(split[i].endsWith("jpg")){
                System.out.println(split[i]);
            }
        }
    }
}
